import React, { Component } from 'react'
import { connect } from "dva"
import {withRouter} from "dva/router";

import MainLayout from '../components/MainLayout/MainLayout'

class App extends Component{
  render () {
    let {children, location} = this.props
    console.log(this.props)
    console.log(children)
    console.log(location)
    return (
      <MainLayout location={location}>
        {children}
      </MainLayout>
    )
  }
}

App.protoTypes = {}

export default withRouter(
  connect(({app,loading}) => ({app,loading}))(App)
)
